package com.yanqu.road.server.logic.system;

import com.yanqu.road.entity.enums.eLogMoneyType;
import com.yanqu.road.entity.enums.eSystemId;
import com.yanqu.road.server.gameplayer.GamePlayer;
import com.yanqu.road.server.gameplayer.module.player.CurrencyModule;
import com.yanqu.road.server.gameplayer.module.player.PlayerModule;
import com.yanqu.road.server.manger.config.SystemOpenMgr;

import java.math.BigInteger;

public abstract class BaseSystemOpen {

    protected int systemId;

    private BigInteger systemValue;

    protected GamePlayer player;

    public BaseSystemOpen(int systemId, GamePlayer player) {
        this.systemId = systemId;
        this.player = player;
        systemValue = BigInteger.valueOf(2).pow(systemId);
    }

    public int getSystemId() {
        return systemId;
    }

    public void checkSystemOpen(){
        BigInteger systemOpenValue = player.getUserInfo().getSystemOpenValue();
        if(SystemOpenMgr.systemOpen(player, systemId)){
            if(systemValue.compareTo(systemOpenValue.and(systemValue)) != 0){
                systemOpenValue = systemOpenValue.add(systemValue);
                player.getUserInfo().setSystemOpenValue(systemOpenValue);
                player.getModule(CurrencyModule.class).addCurrency(SystemOpenMgr.getSystemOpenInfo(systemId).getReward(), eLogMoneyType.System,
                        eLogMoneyType.SystemOpen);
                initSystem();
                player.getModule(PlayerModule.class).syncSystemOpen();
            }
            return;
        }
        if (systemId == eSystemId.FishPond.getValue()) {
            if (systemValue.compareTo(systemOpenValue.and(systemValue)) == 0) {
                systemOpenValue = systemOpenValue.subtract(systemValue);
                player.getUserInfo().setSystemOpenValue(systemOpenValue);
                player.getModule(PlayerModule.class).syncSystemOpen();
            }
        }
    }

    public abstract void initSystem();

    public static BaseSystemOpen createBaseSystemOpen(int systemId, GamePlayer player){
        if(eSystemId.Patrons.getValue() == systemId){
            return new SystemOpenPatrons(systemId, player);
        }else if(eSystemId.Pass.getValue() == systemId){
            return new SystemOpenPass(systemId, player);
        }else if(eSystemId.EstateWar.getValue() == systemId){
            return new SystemOpenEstateWar(systemId, player);
        }else if(eSystemId.Vehicle.getValue() == systemId){
            return new SystemOpenVehicle(systemId, player);
        }else if(eSystemId.TradeWar.getValue() == systemId){
            return new SystemOpenTradeWar(systemId, player);
        }else if(eSystemId.Travel.getValue() == systemId){
            return new SystemOpenTravel(systemId, player);
        }else if(eSystemId.MineWar.getValue() == systemId){
            return new SystemOpenMineWar(systemId, player);
        }else if(eSystemId.OreWar.getValue() == systemId){
            return new SystemOpenOreWar(systemId, player);
        }else if(eSystemId.RechargeActivity.getValue() == systemId){
            return new SystemOpenActivity(systemId, player);
        }else if(eSystemId.SevenDayTask.getValue() == systemId){
            return new SystemOpenSevenDayTask(systemId, player);
        }else if(eSystemId.RankActivity.getValue() == systemId){
            return new SystemOpenActivity(systemId, player);
        }else if(eSystemId.TaskActivity.getValue() == systemId){
            return new SystemOpenActivity(systemId, player);
        }else if(eSystemId.TurntableLottery.getValue() == systemId){
            return new SystemOpenTurntableLottery(systemId, player);
        }else if(eSystemId.VipActivity.getValue() == systemId){
            return new SystemOpenActivity(systemId, player);
        }else if(eSystemId.Rank.getValue() == systemId){
            return new SystemOpenRank(systemId, player);
        }else if(eSystemId.PrivilegeCard.getValue() == systemId){
            return new SystemOpenPrivilegeCard(systemId, player);
        }else if(eSystemId.Sign.getValue() == systemId){
            return new SystemOpenSign(systemId, player);
        }else if(eSystemId.DailyTask.getValue() == systemId){
            return new SystemOpenDailyTask(systemId, player);
        }else if(eSystemId.Achievement.getValue() == systemId){
            return new SystemOpenAchievement(systemId, player);
        }else if(eSystemId.Beauty.getValue() == systemId){
            return new SystemOpenBeauty(systemId, player);
        }else if(eSystemId.Child.getValue() == systemId){
            return new SystemOpenChild(systemId, player);
        }else if(eSystemId.Union.getValue() == systemId){
            return new SystemOpenUnion(systemId, player);
        }else if(eSystemId.Hunt.getValue() == systemId){
            return new SystemOpenHunt(systemId, player);
        }else if(eSystemId.Mammon.getValue() == systemId){
            return new SystemOpenMammon(systemId, player);
        }else if(eSystemId.Mall.getValue() == systemId){
            return new SystemOpenMall(systemId, player);
        }else if(eSystemId.PatronsCombActivity.getValue() == systemId){
            return new SystemOpenActivity(systemId, player);
        }else if(eSystemId.Sacrifice.getValue() == systemId){
            return new SystemOpenSacrifice(systemId, player);
        }else if(eSystemId.WelfareActivity.getValue() == systemId){
            return new SystemOpenActivity(systemId, player);
        }else if(eSystemId.PlatformActivity.getValue() == systemId){
            return new SystemOpenActivity(systemId, player);
        }else if(eSystemId.CommonActivity.getValue() == systemId){
            return new SystemOpenActivity(systemId, player);
        }else if(eSystemId.FaceBookActivity.getValue() == systemId){
            return new SystemOpenActivity(systemId, player);
        }else if(eSystemId.BeautyActivity.getValue() == systemId){
            return new SystemOpenActivity(systemId, player);
        }else if(eSystemId.UnionMemberCountActivity.getValue() == systemId){
            return new SystemOpenActivity(systemId, player);
        }else if(eSystemId.EarnSpeedActivity.getValue() == systemId){
            return new SystemOpenActivity(systemId, player);
        }else if(eSystemId.UnionNameActivity.getValue() == systemId){
            return new SystemOpenActivity(systemId, player);
        }else if(eSystemId.PatronsAbilityActivity.getValue() == systemId){
            return new SystemOpenActivity(systemId, player);
        }else if(eSystemId.Banquet.getValue() == systemId){
            return new SystemOpenBanquet(systemId, player);
        }else if(eSystemId.CrossRankActivity.getValue() == systemId){
            return new SystemOpenActivity(systemId, player);
        }else if(eSystemId.BanquetServer.getValue() == systemId){
            return new SystemBanquetServer(systemId, player);
        }else if(eSystemId.BanquetCross.getValue() == systemId){
            return new SystemBanquetCross(systemId, player);
        }else if(eSystemId.ReserveActivity.getValue() == systemId){
            return new SystemOpenActivity(systemId, player);
        }else if(eSystemId.SecretVolume.getValue() == systemId){
            return new SystemOpenSecretVolume(systemId, player);
        }else if(eSystemId.VirtuousPavilion.getValue() == systemId){
            return new SystemOpenActivity(systemId, player);
        }else if(eSystemId.Charitable.getValue() == systemId) {
            return new SystemOpenCharitable(systemId, player);
        }else if(eSystemId.NpcTalk.getValue() == systemId){
            return new SystemOpenNpcTalk(systemId, player);
        }else if(eSystemId.NpcTrade.getValue() == systemId){
            return new SystemOpenNpcTrade(systemId, player);
        }else if(eSystemId.NpcGangFeng.getValue() == systemId){
            return new SystemOpenNpcGangFeng(systemId, player);
        }else if (eSystemId.Skin.getValue() == systemId) {
            return new SystemOpenActivity(systemId, player);
        }else if (eSystemId.CatTreasure.getValue() == systemId) {
            return new SystemOpenCatTreasure(systemId, player);
        }else if (eSystemId.MysteriousMerchantActivity.getValue() == systemId) {
            return new SystemOpenActivity(systemId, player);
        }else if (eSystemId.EarnSpeedFundActivity.getValue() == systemId) {
            return new SystemOpenEarnSpeedFundActivity(systemId, player);
        }else if (eSystemId.HuaShiGang.getValue() == systemId) {
            return new SystemOpenActivity(systemId, player);
        }else if (eSystemId.Pageant.getValue() == systemId) {
            return new SystemOpenPageant(systemId, player);
        } else if (eSystemId.ThrowingPotActivity.getValue() == systemId) {
            return new SystemOpenThrowingPot(systemId, player);
        }else if(eSystemId.Inn.getValue() == systemId){
            return new SystemOpenInn(systemId, player);
        }else if(eSystemId.ZhaoShang.getValue() == systemId){
            return new SystemOpenZhaoshang(systemId, player);
        }else if(eSystemId.CombVehicle.getValue() == systemId){
            return new SystemOpenCombVehicle(systemId, player);
        }else if(eSystemId.PatronsSkinCombActivity.getValue() == systemId){
            return new SystemOpenActivity(systemId, player);
        } else if (eSystemId.WishPoolActivity.getValue() == systemId) {
            return new SystemOpenWishPool(systemId, player);
        }else if(eSystemId.YearMaster.getValue() == systemId){
            return new SystemOpenYearMaster(systemId, player);
        }else if(eSystemId.ChinaPublicTestActivity.getValue() == systemId){
            return new SystemOpenActivity(systemId, player);
        } else if (eSystemId.StrongholdActivity.getValue() == systemId) {
            return new SystemStrongholdOpen(systemId, player);
        } else if (eSystemId.Ppl.getValue() == systemId) {
            return new SystemOpenPpl(systemId, player);
        }else if(eSystemId.TreasureActivity.getValue() == systemId){
            return new SystemOpenTreasure(systemId, player);
        }else if (eSystemId.JianChuangHuaActivity.getValue() == systemId) {
            return new SystemOpenJianChuangHua(systemId, player);
        }else if (eSystemId.DrawPicturesActivity.getValue() == systemId) {
            return new SystemOpenDrawPictures(systemId, player);
        }else if(eSystemId.DaFuWeng.getValue() == systemId){
            return new SystemOpenActivity(systemId, player);
        }else if (eSystemId.SpringFestivalActivity.getValue() == systemId) {
            return new SystemOpenSpringFestival(systemId, player);
        }else if(eSystemId.UnionWarActivity.getValue() == systemId){
            return new SystemOpenUnionWar(systemId, player);
        }else if (eSystemId.Variety.getValue() == systemId) {
            return new SystemOpenVariety(systemId, player);
        }else if(eSystemId.TangHuluActivity.getValue() == systemId){
            return new SystemOpenTangHuLu(systemId, player);
        }else if (eSystemId.Clinic.getValue() == systemId) {
            return new SystemOpenClinic(systemId, player);
        }else if (eSystemId.ShuiHuActivity.getValue() == systemId) {
            return new SystemOpenShuiHuActivity(systemId, player);
        }else if (eSystemId.YiTongQu.getValue() == systemId) {
            return new SystemOpenYiTongQu(systemId, player);
        }else if(eSystemId.BowArtActivity.getValue() == systemId){
            return new SystemOpenBowArt(systemId, player);
        } else if (eSystemId.GhostActivity.getValue() == systemId) {
            return new SystemOpenGhost(systemId, player);
        } else if (eSystemId.ZhanLingActivity.getValue() == systemId) {
            return new SystemZhanLing(systemId, player);
        } else if (eSystemId.SuoYaoActivity.getValue() == systemId) {
            return new SystemOpenSuoYaoActivity(systemId, player);
        } else if(eSystemId.BusyFarmingActivity.getValue() == systemId){
            return new SystemOpenBusyFarming(systemId, player);
        } else if (eSystemId.EarnSpeedFundPlusActivity.getValue() == systemId) {
            return new SystemOpenEarnSpeedPlusFundActivity(systemId, player);
        } else if (eSystemId.HangHaiActivity.getValue() == systemId) {
            return new SystemOpenHangHai(systemId, player);
        } else if (eSystemId.PawnshopActivity.getValue() == systemId) {
            return new SystemOpenPawnshop(systemId, player);
        } else if (eSystemId.HouseBank.getValue() == systemId) {
            return new SystemOpenHouseBank(systemId, player);
        } else if (eSystemId.GuGuoXunBaoActivity.getValue() == systemId){
            return new SystemOpenGuGuoXunBao(systemId, player);
        } else if (eSystemId.ThiefSystem.getValue() == systemId) {
            return new SystemOpenThief(systemId, player);
        } else if (eSystemId.DrinkActivity.getValue() == systemId) {
            return new SystemOpenDrink(systemId, player);
        } else if (eSystemId.SummerFestivalActivity.getValue() == systemId) {
            return new SystemOpenSummerFestival(systemId, player);
        }else if(eSystemId.DragonBoatRaceActivity.getValue() == systemId) {
            return new SystemOpenDragonBoatRace(systemId, player);
        } else if (eSystemId.ManorSystem.getValue() == systemId) {
            return new SystemOpenManor(systemId, player);
        } else if (eSystemId.SanFuTian.getValue() == systemId) {
            return new SystemOpenSanFuTian(systemId, player);
        } else if (eSystemId.XiaYueActivity.getValue() == systemId) {
            return new SystemOpenXiaYue(systemId, player);
        } else if (eSystemId.DunHuangShiKuActivity.getValue() == systemId) {
            return new SystemOpenDunHuangShiKuActivity(systemId, player);
        } else if (eSystemId.BeautyEscort.getValue() == systemId){
            return new SystemOpenBeautyEscort(systemId, player);
        }else if (eSystemId.CookBoySkinActivity.getValue() == systemId) {
            return new SystemCookBoySkinActivity(systemId, player);
        }else if (eSystemId.CookBoyDoor.getValue() == systemId) {
            return new SystemCookBoyOpen(systemId, player);
        }else if (eSystemId.ChefDuelDoor.getValue() == systemId) {
            return new SystemCookBoyOpen(systemId, player);
        }else if (eSystemId.CookBoyActivity1.getValue() == systemId) {
            return new SystemCookBoyProcess1(systemId, player);
        }else if (eSystemId.CookBoyActivity2.getValue() == systemId) {
            return new SystemCookBoyProcess2(systemId, player);
        }else if (eSystemId.CookBoyActivity3.getValue() == systemId) {
            return new SystemCookBoyProcess3(systemId, player);
        }else if (eSystemId.ChefDuelPhase2.getValue() == systemId) {
            return new SystemChefDuelProcess2(systemId, player);
        }else if (eSystemId.ChefDuelPhase3.getValue() == systemId) {
            return new SystemChefDuelProcess3(systemId, player);
        } else if (eSystemId.MammonHall.getValue() == systemId){
            return new SystemOpenMamomHall(systemId, player);
        } else if (eSystemId.CelebrationActivity.getValue() == systemId) {
            return new SystemOpenCelebrationActivity(systemId, player);
        } else if (eSystemId.AnniversaryActivity.getValue() == systemId) {
            return new SystemOpenAnniversaryActivity(systemId, player);
        } else if (eSystemId.LanRuoSiActivity.getValue() == systemId){
            return new SystemOpenLanRuoSi(systemId, player);
        } else if (eSystemId.WineShop.getValue() == systemId) {
            return new SystemOpenWineShop(systemId, player);
        } else if (eSystemId.BeautyFund.getValue() == systemId) {
            return new SystemOpenBeautyFund(systemId, player);
        } else if (eSystemId.BeautyHigherFund.getValue() == systemId) {
            return new SystemOpenBeautyHigherFund(systemId, player);
        } else if (eSystemId.GuiChuiDengActivity.getValue() == systemId) {
            return new SystemOpenGuiChuiDeng(systemId, player);
        } else if (eSystemId.GourdChildActivity.getValue() == systemId){
            return new SystemOpenGourdChild(systemId, player);
        } else if (eSystemId.GourdPlantActivity.getValue() == systemId){
            return new SystemOpenGourdPlant(systemId, player);
        } else if (eSystemId.Assistant.getValue() == systemId) {
            return new SystemOpenAssistant(systemId, player);
        } else if (eSystemId.MonopolyMarket.getValue() == systemId) {
            return new SystemOpenMonopolyMarket(systemId, player);
        } else if (eSystemId.WinterLoveActivity.getValue() == systemId){
            return new SystemOpenWinterLove(systemId,player);
        } else if (eSystemId.YingXinActivity.getValue() == systemId) {
            return new SystemOpenYingXin(systemId, player);
        } else if (eSystemId.FishPond.getValue() == systemId) {
            return new SystemOpenFishPond(systemId, player);
        } else if (eSystemId.HellActivity.getValue() == systemId){
            return new SystemHellActivity(systemId, player);
        }else if (eSystemId.MountainAdnSeaCombVehicle.getValue() == systemId){
            return new SystemOpenMountainAdnSeaCombVehicle(systemId, player);
        } else if (eSystemId.ShareActivity.getValue() == systemId) {
            return new SystemOpenShareActivity(systemId,player);
        } else if (eSystemId.FourActivity.getValue() == systemId) {
            return new SystemOpenFourActivity(systemId, player);
        } else if (eSystemId.DailyDiscount.getValue() == systemId) {
            return new SystemOpenDailyDiscountActivity(systemId, player);
        } else if (eSystemId.WealthGodGifts.getValue() == systemId) {
            return new SystemOpenWealthGodGiftsActivity(systemId, player);
        } else if (eSystemId.ServerOpenGifts.getValue() == systemId) {
            return new SystemOpenServerOpenGiftsActivity(systemId, player);
        } else if (eSystemId.XiaowuRecall.getValue() == systemId){
            return new SystemXiaowuRecallOpen(systemId,player);
        } else if (eSystemId.GrandChild.getValue() == systemId) {
            return new SystemOpenGrandChild(systemId, player); // 暂时用这个
        } else if (eSystemId.DouLuoDaLuActivity.getValue() == systemId){
            return new SystemOpenDouLuoDaLu(systemId, player);
        }else if (eSystemId.DouLuoShrekActivity.getValue() == systemId){
            return new SystemOpenShrekActivity(systemId, player);
        } else if (eSystemId.OldPlayerReturn.getValue() == systemId) {
            return new SystemOldPlayerReturn(systemId, player);
        } else if (eSystemId.ChannelRankActivity.getValue() == systemId) {
            return new SystemOpenActivity(systemId, player);
        } else if (eSystemId.TigerYearSpringFestivalActivity.getValue() == systemId) {
            return new SystemOpenTigerYear(systemId, player);
        }else if (eSystemId.ShuiHuYeZiCardActivity.getValue() == systemId) {
            return new SystemOpenShuiHuYeZiActivity(systemId, player);
        } else if (eSystemId.SpringDinner.getValue() == systemId) {
            return new SystemSpringDinnerActivity(systemId, player);
        } else if (eSystemId.TaoBao.getValue() == systemId) {
            return new SystemTaoBaoActivity(systemId, player);
        } else if (eSystemId.Seacraft.getValue() == systemId) {
            return new SystemSeacraftActivity(systemId, player);
        } else if (eSystemId.PalaceActivity.getValue() == systemId) {
            return new SystemOpenPalace(systemId, player);
        } else if (eSystemId.ToyHouse.getValue() == systemId) {
            return new SystemOpenToyHouse(systemId, player);
        } else if (eSystemId.CrossHuaBen.getValue() == systemId){
            return new CrossHuaBenSystemOpen(systemId, player);
        } else if (eSystemId.WingRoomUnlockTask.getValue() == systemId) {
            return new eSystemWingRoomUnlockTask(systemId, player);
        } else if (eSystemId.WingRoom.getValue() == systemId) {
            return new SystemOpenWingRoom(systemId, player);
        }else if (eSystemId.ChineseChess.getValue() == systemId) {
            return new SystemChineseChessActivity(systemId, player);
        } else if(eSystemId.ShuShan.getValue() == systemId){
            return new SystemOpenShuShanActivity(systemId, player);
        } else if (eSystemId.TongBing.getValue() == systemId || eSystemId.TongBingCityLord.getValue() == systemId) {
            return new SystemOpenActivity(systemId, player);
        } else if (eSystemId.MetaSpace.getValue() == systemId) {
            return new SystemOpenMetaSpace(systemId, player);
        } else if (eSystemId.PaintedEggs.getValue() == systemId) {
            return new SystemOpenPaintedEggs(systemId, player);
        } else if (eSystemId.DrugStore.getValue() == systemId){
            return new DrugStoreSystemOpen(systemId, player);
        } else if(eSystemId.XiaoYuGift.getValue() == systemId){
            return new SystemOpenXiaoYuGift(systemId, player);
        } else if(eSystemId.ZhouNianTurntable.getValue() == systemId){
            return new SystemOpenZhouNianTurntable(systemId, player);
        } else if(eSystemId.MemoryPieces.getValue() == systemId){
            return new SystemOpenMemoryPieces(systemId, player);
        } else if (eSystemId.BusinessReunion.getValue() == systemId) {
            return new SystemOpenBusinessReunionActivity(systemId, player);
        } else if (eSystemId.RecallPlayerActivity.getValue() == systemId){
            return new SystemOpenRecallPlayerActivity(systemId, player);
        } else if (eSystemId.YearBooks.getValue() == systemId) {
            return new SystemOpenYearBook(systemId, player);
        } else if (eSystemId.AnniversaryCarnival.getValue() == systemId) {
            return new SystemOpenAnniversaryCarnival(systemId, player);
        } else if (eSystemId.BadgeShow.getValue() == systemId) {
            return new SystemOpenBadgeShow(systemId, player);
        } else if (eSystemId.ClimbTowerActivity.getValue() == systemId){
            return new SystemOpenClimbTower(systemId, player);
        } else if (eSystemId.XuanYuanZhiXiaActivity.getValue() == systemId){
            return new XuanYuanZhiXiaActivitySystemOpen(systemId, player);
        } else if (eSystemId.XiaYeYouActivity.getValue() == systemId){
            return new XiaYeYouActivitySystemOpen(systemId, player);
        } else if (eSystemId.Winery.getValue() == systemId) {
            return new SystemOpenWineryActivity(systemId, player);
        } else if (eSystemId.OperaMask.getValue() == systemId) {
            return new SystemOpenOperaMask(systemId, player);
        } else if (eSystemId.PlatformAntiFraudActivity.getValue() == systemId){
            return new PlatformAntiFraudSystemOpen(systemId, player);
        } else if (eSystemId.NewServerWelfareActivity.getValue() == systemId){
            return new SystemOpenNewServerWelfare(systemId,player);
        } else if (eSystemId.RankUnionWar.getValue() == systemId) {
            return new SystemRankUnionWarActivity(systemId, player);
        } else if (eSystemId.FellingTreesActivity.getValue() == systemId) {
            return new SystemOpenFellingTrees(systemId, player);
        } else if (eSystemId.WanXinBuLuoReward.getValue() == systemId){
            return new SystemOpenWanXinBuLuoReward(systemId, player);
        } else if (eSystemId.Pasture.getValue() == systemId) {
            return new SystemOpenPasture(systemId, player);
        } else if (eSystemId.CrossPasture.getValue() == systemId) {
            return new SystemOpenCrossPasture(systemId, player);
        } else if (eSystemId.WasheAreaPk.getValue() == systemId) {
            return new SystemWasheAreaPkActivityOpen(systemId, player);
        } else if (eSystemId.Tomb.getValue() == systemId){
            return new SystemOpenTomb(systemId,player);
        } else if (eSystemId.GreatTradeActivity.getValue() == systemId){
            return new SystemOpenGreatTrade(systemId, player);
        } else if (eSystemId.TwinsActivity.getValue() == systemId) {
            return new SystemTwinsActivity(systemId, player);
        } else if (eSystemId.SmallGame.getValue() == systemId) {
            return new SystemOpenSmallGame(systemId, player);
        } else if (eSystemId.WasheActivity.getValue() == systemId) {
            return new SystemOpenWashe(systemId, player);
        } else if(eSystemId.EggsActivity.getValue() == systemId){
            return new SystemOpenEggsActivity(systemId, player);
        } else if (eSystemId.Cricket.getValue() == systemId) {
            return new SystemOpenCricket(systemId, player);
        } else if (eSystemId.CatActivity.getValue() == systemId){
            return new SystemOpenCatActivity(systemId, player);
        } else if (eSystemId.WorldCupActivity.getValue() == systemId) {
            return new SystemOpenWorldCup(systemId, player);
        } else if (eSystemId.LuckyDrawActivity.getValue() == systemId) {
            return new SystemOpenLuckyDraw(systemId, player);
        } else if (eSystemId.PeakStrongholdActivity.getValue() == systemId) {
            return new SystemOpenPeakStronghold(systemId, player);
        } else if (eSystemId.LionDanceActivity.getValue() == systemId) {
            return new SystemOpenLionDance(systemId, player);
        } else if (eSystemId.LionDanceEntryActivity.getValue() == systemId){
            return new LionDanceEntryActivitySystemOpen(systemId, player);
        } else if (eSystemId.CarpTripActivity.getValue() == systemId){
            return new SystemOpenCarpTrip(systemId, player);
        } else if (eSystemId.GuangzhouCultureActivity.getValue() == systemId){
            return new SystemGuangzhouCultureActivity(systemId, player);
        } else if (eSystemId.NewYearBagActivity.getValue() == systemId) {
            return new SystemOpenNewYearBag(systemId, player);
        } else if (eSystemId.FireWork2023.getValue() == systemId){
            return new SystemOpenFireWork(systemId, player);
        } else if (eSystemId.FanXiuSpring.getValue() == systemId){
            return new SystemOpenFanXiuSpring(systemId, player);
        } else if (eSystemId.XiuXian.getValue() == systemId){
            return new SystemOpenXiuXianActivity(systemId, player);
        } else if (eSystemId.JieShi.getValue() == systemId){
            return new SystemOpenJieShiActivity(systemId, player);
        } else if (eSystemId.FlowerCards.getValue() == systemId){
            return new SystemOpenFlowerCard(systemId, player);
        } else if (eSystemId.GoldAutumnActivity.getValue() == systemId){
            return new SystemOpenGoldAutumn(systemId, player);
        } else if (eSystemId.CricketFund.getValue() == systemId){
            return new SystemOpenCricketFund(systemId, player);
        } else if (eSystemId.PeakSeacraft.getValue() == systemId) {
            return new SystemPeakSeacraftActivity(systemId, player);
        } else if (eSystemId.AdActivity.getValue() == systemId){
            return new SystemOpenAdActivity(systemId, player);
        } else if (eSystemId.PeerlessBeautyLottery.getValue() == systemId){
            return new SystemOpenPeerlessBeautyLotteryActivity(systemId, player);
        } else if (eSystemId.WeekCard.getValue() == systemId){
            return new SystemOpenWeekCard(systemId, player);
        } else if (eSystemId.TonBing.getValue() == systemId || eSystemId.TonBingCityLord.getValue() == systemId) {
            return new SystemOpenActivity(systemId, player);
        } else if (eSystemId.GoddessActivityId.getValue() == systemId){
            return new SystemOpenGoddess(systemId, player);
        } else if (eSystemId.HongXian.getValue() == systemId){
            return new SystemOpenHongXian(systemId, player);
        } else if (eSystemId.SummerGamesActivity.getValue() == systemId){
            return new SystemOpenSummerGames(systemId, player);
        } else if (eSystemId.SoulBoneLotteryActivity.getValue() == systemId){
            return new SystemOpenSoulBoneLottery(systemId, player);
        } else if (eSystemId.SummerQuizActivity.getValue() == systemId){
            return new SystemOpenSummerQuiz(systemId, player);
        } else if (eSystemId.RecoveryReward.getValue() == systemId) {
            return new SystemOpenRecoveryReward(systemId, player);
        } else if (eSystemId.UnionChest.getValue() == systemId) {
            return new SystemUnionChestOpen(systemId, player);
        } else if (eSystemId.MogulBirthday.getValue() == systemId){
            return new SystemOpenMogulBirthday(systemId, player);
        } else if (eSystemId.CommonWishDraw.getValue() == systemId){
            return new SystemOpenCommonWish(systemId, player);
        } else if (eSystemId.DeepFishing.getValue() == systemId){
            return new SystemOpenDeepFishing(systemId,player);
        } else if (eSystemId.FiveHeroActivity.getValue() == systemId){
            return new SystemOpenFiveHore(systemId, player);
        } else if (eSystemId.LangYaMemorial.getValue() == systemId){
            return new SystemOpenLangYaMemorial(systemId, player);
        }  else if (eSystemId.LangYaBang.getValue() == systemId){
            return new SystemOpenLangYaBang(systemId,player);
        }  else if (eSystemId.Kowloon.getValue() == systemId){
            return new SystemOpenKowloon(systemId,player);
        }  else if (eSystemId.Kuang.getValue() == systemId){
            return new SystemOpenKuang(systemId,player);
        }  else if (eSystemId.SignInDrawActivity.getValue() == systemId){
            return new SystemOpenSignInDraw(systemId, player);
        } else if (eSystemId.SilkRoad.getValue() == systemId){
            return new SystemOpenSilkRoadActivity(systemId, player);
        } else if (eSystemId.Advertisement.getValue() == systemId){
            return new SystemOpenAdvertisementActivity(systemId, player);
        } else if (eSystemId.UnionCampWar.getValue() == systemId){
            return new SystemOpenUnionCampWar(systemId, player);
        } else if (eSystemId.MeiTuanDesktop.getValue() == systemId){
            return new SystemOpenMeiTuanDeskTopActivity(systemId, player);
        } else if (eSystemId.SpecialCookBoy.getValue() == systemId){
            return new SystemOpenSpecialCookBoy(systemId, player);
        } else if (eSystemId.SpecialCookBoySevenSign.getValue() == systemId){
            return new SystemOpenSpecialCookBoySevenSign(systemId, player);
        } else if (eSystemId.FlowerStudy.getValue() == systemId){
            return new SystemOpenFlowerStudy(systemId, player);
        } else if (eSystemId.WanYao.getValue() == systemId) {
            return new SystemOpenWanYao(systemId, player);
        } else if (eSystemId.VehicleSoul.getValue() == systemId) {
            return new SystemOpenVehicleSoul(systemId, player);
        } else if (eSystemId.Qixi.getValue() == systemId){
            return new SystemOpenQixi(systemId, player);
        } else if (eSystemId.GuaGifts.getValue() == systemId){
            return new SystemOpenGuaGifts(systemId, player);
        } else if (eSystemId.NewMonopolyMarket.getValue() == systemId){
            return new SystemOpenNewMonopolyMarket(systemId, player);
        }else if (eSystemId.DigGold.getValue() == systemId){
            return new SystemOpenDigGold(systemId, player);
        } else if(eSystemId.PatronLevelFund.getValue() == systemId){
            return new SystemOpenActivity(systemId, player);
        } else if (eSystemId.SpecialTombRobSign.getValue() == systemId){
            return new SystemOpenSpecialTombRobSign(systemId, player);
        } else if (eSystemId.EveFeast.getValue() == systemId) {
            return new SystemOpenEveFeast(systemId, player);
        } else if (eSystemId.DaoMu.getValue() == systemId){
            return new SystemOpenDaoMu(systemId, player);
        } else if (eSystemId.SuiTang.getValue() == systemId){
            return new SystemOpenSuiTang(systemId, player);
        } else if (eSystemId.LingYan.getValue() == systemId){
            return new SystemOpenLingYan(systemId, player);
        } else if (eSystemId.QQPrivilege.getValue() == systemId){
            return new SystemOpenQQPrivilege(systemId, player);
        } else if (eSystemId.MailSub37.getValue() == systemId){
            return new SystemOpen37MailSub(systemId, player);
        } else if (eSystemId.PatronsFund.getValue() == systemId){
            return new SystemOpenPatronsFund(systemId, player);
        } else if (eSystemId.DaoMuSpecial.getValue() == systemId){
            return new SystemOpenDaoMuSpecial(systemId, player);
        } else if (eSystemId.FestivalGift.getValue() == systemId){
            return new SystemOpenFestivalGift(systemId, player);
        } else if (eSystemId.NewFirstRecharge.getValue() == systemId || systemId == eSystemId.NewFirstRecharge2024.getValue()){
            return new SystemOpenNewFirstRecharge(systemId, player);
        } else if (eSystemId.WitchDraw.getValue() == systemId){
            return new SystemOpenWitchDraw(systemId, player);
        } else if (eSystemId.JinLi.getValue() == systemId) {
            return new SystemOpenJinLi(systemId, player);
        } else if (eSystemId.SteleSoul.getValue() == systemId) {
            return new SystemOpenSteleSoul(systemId, player);
        } else if (eSystemId.Chakra.getValue() == systemId){
            return new SystemOpenWingRoomChakra(systemId, player);
        } else if (eSystemId.MusicRoom.getValue() == systemId){
            return new SystemOpenMusicRoom(systemId, player);
        } else if (eSystemId.MusicRoomRank.getValue() == systemId){
            return new SystemOpenActivity(systemId, player);
        } else if (eSystemId.JiuZhou.getValue() == systemId) {
            return new SystemOpenJiuZhou(systemId, player);
        } else if (eSystemId.SnowGarden.getValue() == systemId) {
            return new SystemOpenSnowGarden(systemId, player);
        } else if (eSystemId.ZfbIndexSetting.getValue() == systemId) {
            return new SystemOpenZfbIndexSetting(systemId, player);
        } else if (eSystemId.Curio.getValue() == systemId){
            return new SystemOpenCurio(systemId, player);
        } else if (eSystemId.LuckyShop.getValue() == systemId){
            return new SystemOpenLuckyShop(systemId, player);
        } else if (eSystemId.RuiShou.getValue() == systemId) {
            return new SystemOpenRuiShou(systemId, player);
        } else if (eSystemId.DoubleSpring.getValue() == systemId){
            return new SystemOpenDoubleSpring(systemId, player);
        } else if (eSystemId.DragonsEntrance.getValue() == systemId){
            return new SystemOpenActivity(systemId, player);
        } else if (eSystemId.PiXiuActivity.getValue() == systemId){
            return new SystemOpenPiXiuActivity(systemId, player);
        } else if (eSystemId.SpringBanquet.getValue() == systemId){
            return new SystemOpenSpringUnionBanquet(systemId, player);
        } else if (eSystemId.ZhenHuanFirstProcess.getValue() == systemId){
            return new SystemOpenZhenHuanActivity(systemId, player);
        } else if (eSystemId.ZhenHuanSecondProcess.getValue() == systemId) {
            return new SystemOpenZhenHuanActivity(systemId, player);
        } else if (eSystemId.ZhenHuanThirdProcess.getValue() == systemId){
            return new SystemOpenZhenHuanActivity(systemId, player);
        } else if (eSystemId.DaySign.getValue() == systemId){
            return new SystemOpenActivity(systemId, player);
        } else if (eSystemId.ZhenHuanTotalEnter.getValue() == systemId){
            return new SystemOpenActivity(systemId, player);
        } else if (eSystemId.BiaoJu.getValue() == systemId) {
            return new SystemOpenBiaoJuActivity(systemId, player);
        } else if (eSystemId.SpringDraw.getValue() == systemId){
            return new SystemOpenSpringDraw(systemId, player);
        } else if (eSystemId.AnniversaryPreheat.getValue() == systemId){
            return new SystemOpenAnniversaryPreheat(systemId, player);
        } else if (eSystemId.FoxCard.getValue() == systemId) {
            return new SystemOpenFoxCardActivity(systemId, player);
        } else if (eSystemId.FoxSevenDaySign.getValue() == systemId) {
            return new SystemOpenActivity(systemId, player);
        } else if (eSystemId.SevenDaySign330.getValue() == systemId) {
            return new SystemOpenActivity(systemId, player);
        } else if (eSystemId.Harps.getValue() == systemId){
            return new SystemOpenHarps(systemId, player);
        } else if (eSystemId.SonHai.getValue() == systemId){
            return new SystemOpenSonHai(systemId, player);
        } else if (eSystemId.VehicleBone.getValue() == systemId){
            return new SystemOpenVehicleStone(systemId, player);
        } else if (eSystemId.HsIsland.getValue() == systemId) {
            return new SystemOpenHsIsland(systemId, player);
        } else if (eSystemId.FeastActivity.getValue() == systemId){
            return new SystemOpenFeastActivity(systemId, player);
        } else if (eSystemId.Turtle.getValue() == systemId) {
            return new SystemOpenTurtleActivity(systemId, player);
        } else if (eSystemId.AdLoginMall.getValue() == systemId){
            return new SystemOpenActivity(systemId, player);
        } else if (eSystemId.AdSevenSignMall.getValue() == systemId){
            return new SystemOpenActivity(systemId, player);
        } else if (eSystemId.HorseRun.getValue() == systemId){
            return new SystemOpenHorseRunActivity(systemId,player);
        } else if (eSystemId.GoldIngot.getValue() == systemId) {
            return new SystemOpenGoldIngotFund(systemId, player);
        } else if (eSystemId.HotpotJump.getValue() == systemId) {
            return new SystemOpenHotpotJump(systemId, player);
        } else if (eSystemId.Gashapon.getValue() == systemId) {
            return new SystemOpenGashaponActivity(systemId, player);
        } else if (eSystemId.StarLight.getValue() == systemId) {
            return new SystemOpenStarLightActivity(systemId, player);
        } else if (eSystemId.Apprentice.getValue() == systemId) {
            return new SystemOpenApprentice(systemId, player);
        } else if(eSystemId.YuanBaoLottery.getValue() == systemId){
            return new SystemOpenYuanBaoLottery(systemId, player);
        } else if (eSystemId.WealthScroll.getValue() == systemId) {
            return new SystemOpenWealthScroll(systemId, player);
        } else if (eSystemId.TravelBook.getValue() == systemId) {
            return new SystemOpenTravelBook(systemId, player);
        } else if (eSystemId.XingYouShanShui.getValue() == systemId) {
            return new SystemOpenYouXingShanShui(systemId, player);
        } else if (eSystemId.IceServer.getValue() == systemId) {
            return new SystemOpenIceServer(systemId, player);
        } else if (eSystemId.IceServerSevenDay.getValue() == systemId) {
            return new SystemOpenIceServerSevenDay(systemId, player);
        } else if (eSystemId.ChefDuelPhase1.getValue() == systemId) {
            return new SystemOpenChefDuelPhase1(systemId, player);
        } else if (eSystemId.ChefDuelSevenDaySign.getValue() == systemId) {
            return new SystemOpenActivity(systemId, player);
        } else if (eSystemId.ChuHanZB.getValue() == systemId) {
            return new SystemOpenChuHan(systemId, player);
        } else if (eSystemId.YQHotel.getValue() == systemId) {
            return new SystemOpenYQHotelActivity(systemId, player);
        }else if (eSystemId.BusinessDepart.getValue() == systemId) {
            return new SystemOpenActivity(systemId, player);
        } else if (eSystemId.IceServerBuilding.getValue() == systemId) {
            return new SystemOpenIceServerBuilding(systemId, player);
        } else if (eSystemId.IceServerGift.getValue() == systemId) {
            return new SystemOpenIceServerGiftActivity(systemId, player);
        } else if (eSystemId.ChannelMusicRoomRank.getValue() == systemId) {
            return new SystemOpenChannelMusicRoomRank(systemId,player);
        }
        return null;
    }
}
